<?php

namespace app\api\controller;

use app\api\service\InfoService;
use app\common\Common;
use think\facade\Request;

class Info extends Base
{
    private $service;

    public function __construct(InfoService $infoService)
    {
        parent::__construct();
        $this->service = $infoService;
    }

    // 获取微故事列表
    public function microStoryList()
    {
        $params = Request::param();

        $data = $this->service->getMicroStoryList($params);

        return Common::success($data);
    }

    // 获取微故事详情
    public function microStoryDetail()
    {
        $params = Request::param();

        $data = $this->service->getMicroStoryDetail($params['id']);

        return Common::success($data);
    }

    // 获取剧照列表
    public function stillsList()
    {
        $params = Request::param();

        $data = $this->service->getStillsList($params);

        return Common::success($data);
    }
}